
<html><head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta content="text/javascript" http-equiv="content-script-type">
<title>maths.Misc</title>
<link rel="stylesheet" type="text/css" href="candydoc/style.css">
<!--[if lt IE 7]><link rel="stylesheet" type="text/css" href="candydoc/ie56hack.css"><![endif]-->
<script language="JavaScript" src="candydoc/util.js" type="text/javascript"></script>
<script language="JavaScript" src="candydoc/tree.js" type="text/javascript"></script>
<script language="JavaScript" src="candydoc/explorer.js" type="text/javascript"></script>
</head><body>
<div id="tabarea"></div><div id="explorerclient"></div>
<div id="content"><script>explorer.initialize("maths.Misc", "candydoc/");</script>
	<table class="content">
		<tr><td id="docbody"><h1>maths.Misc</h1><!-- Generated by Ddoc from C:\Projects\necrophilia\tests\shared\maths\Misc.d -->
<br><br>

<script>explorer.outline.incSymbolLevel();</script>
<dl>
<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">void 
<span class="currsymbol">cartesianToSpherical</span>
<script>explorer.outline.addDecl('cartesianToSpherical');</script>

(real <span class="funcparam">x</span>, real <span class="funcparam">y</span>, real <span class="funcparam">z</span>, real* <span class="funcparam">phi</span>, real* <span class="funcparam">theta</span>, real* <span class="funcparam">r</span>);
</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>Convert the specfied [<span class="funcparam">x</span> <span class="funcparam">y</span> <span class="funcparam">z</span>] coordinates to spherical [pi <span class="funcparam">theta</span> <span class="funcparam">r</span>]
<br><br>

</dd>

<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">void 
<span class="currsymbol">cartesianToSpherical</span>
<script>explorer.outline.addDecl('cartesianToSpherical');</script>

(real <span class="funcparam">x</span>, real <span class="funcparam">y</span>, real <span class="funcparam">z</span>, real* <span class="funcparam">phi</span>, real* <span class="funcparam">theta</span>);
</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>Convert the specfied [<span class="funcparam">x</span> <span class="funcparam">y</span> <span class="funcparam">z</span>] coordinates to spherical [pi <span class="funcparam">theta</span>]
<br><br>

</dd>

<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">template 
<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

(T)</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>'Nearest' interpolation function
<br><br>
<b>Params:</b><br>
<table><tr>
<td nowrap valign="top" style="padding-right: 8px">t</td>

               
<td>= time, a float from [0, 1]</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">a</td>

               
<td>= first value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">b</td>

               
<td>= second value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">res</td>

               
<td>= a place to put the result in</td></tr>
</table><br>
<b>Remarks:</b><br>

<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

(&lt; 0.5, a, b, res), res == a
	
<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

(&gt;= 0.5, a, b, res), res == b
<br><br>


<script>explorer.outline.incSymbolLevel();</script>
<dl>
<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">template 
<span class="currsymbol">
<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

</span>
<script>explorer.outline.addDecl('
<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

');</script>

(T)</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>'Nearest' interpolation function
<br><br>
<b>Params:</b><br>
<table><tr>
<td nowrap valign="top" style="padding-right: 8px">float <span class="funcparam">t</span></td>

               
<td>= time, <span class="funcparam">a</span> float from [0, 1]</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">a</span></td>

               
<td>= first value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">b</span></td>

               
<td>= second value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">res</span></td>

               
<td>= <span class="funcparam">a</span> place to put the result in</td></tr>
</table><br>
<b>Remarks:</b><br>

<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

(&lt; 0.5, <span class="funcparam">a</span>, <span class="funcparam">b</span>, <span class="funcparam">res</span>), <span class="funcparam">res</span> == <span class="funcparam">a</span>
	
<span class="currsymbol">nearestInterp</span>
<script>explorer.outline.addDecl('nearestInterp');</script>

(&gt;= 0.5, <span class="funcparam">a</span>, <span class="funcparam">b</span>, <span class="funcparam">res</span>), <span class="funcparam">res</span> == <span class="funcparam">b</span>
<br><br>

</dd>
</dl>
<script>explorer.outline.decSymbolLevel();</script>


</dd>

<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">template 
<span class="currsymbol">linearInterp</span>
<script>explorer.outline.addDecl('linearInterp');</script>

(T)</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>'Linear' interpolation function
<br><br>
<b>Params:</b><br>
<table><tr>
<td nowrap valign="top" style="padding-right: 8px">t</td>

               
<td>= time, a float from [0, 1]</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">a</td>

               
<td>= first value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">b</td>

               
<td>= second value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">res</td>

               
<td>= a place to put the result in</td></tr>
</table><br>
<b>Remarks:</b><br>
nearestInterp(0, a, b, res), res == a
	nearestInterp(1, a, b, res), res == b
<br><br>


<script>explorer.outline.incSymbolLevel();</script>
<dl>
<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">template 
<span class="currsymbol">
<span class="currsymbol">linearInterp</span>
<script>explorer.outline.addDecl('linearInterp');</script>

</span>
<script>explorer.outline.addDecl('
<span class="currsymbol">linearInterp</span>
<script>explorer.outline.addDecl('linearInterp');</script>

');</script>

(T)</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>'Linear' interpolation function
<br><br>
<b>Params:</b><br>
<table><tr>
<td nowrap valign="top" style="padding-right: 8px">float <span class="funcparam">t</span></td>

               
<td>= time, <span class="funcparam">a</span> float from [0, 1]</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">a</span></td>

               
<td>= first value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">b</span></td>

               
<td>= second value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">res</span></td>

               
<td>= <span class="funcparam">a</span> place to put the result in</td></tr>
</table><br>
<b>Remarks:</b><br>
nearestInterp(0, <span class="funcparam">a</span>, <span class="funcparam">b</span>, <span class="funcparam">res</span>), <span class="funcparam">res</span> == <span class="funcparam">a</span>
	nearestInterp(1, <span class="funcparam">a</span>, <span class="funcparam">b</span>, <span class="funcparam">res</span>), <span class="funcparam">res</span> == <span class="funcparam">b</span>
<br><br>

</dd>
</dl>
<script>explorer.outline.decSymbolLevel();</script>


</dd>

<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">template 
<span class="currsymbol">catmullRomInterp</span>
<script>explorer.outline.addDecl('catmullRomInterp');</script>

(T)</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>Catmull-rom interpolation function
<br><br>
<b>Params:</b><br>
<table><tr>
<td nowrap valign="top" style="padding-right: 8px">t</td>

               
<td>= time, a float from [0, 1]</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">a</td>

               
<td>= first value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">b</td>

               
<td>= second value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">c</td>

               
<td>= third value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">d</td>

               
<td>= fourth value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">res</td>

               
<td>= a place to put the result in</td></tr>
</table><br>


<script>explorer.outline.incSymbolLevel();</script>
<dl>
<script>explorer.outline.writeEnabled = true;</script>
<dt><span class="decl">template 
<span class="currsymbol">
<span class="currsymbol">catmullRomInterp</span>
<script>explorer.outline.addDecl('catmullRomInterp');</script>

</span>
<script>explorer.outline.addDecl('
<span class="currsymbol">catmullRomInterp</span>
<script>explorer.outline.addDecl('catmullRomInterp');</script>

');</script>

(T)</span></dt>
<script>explorer.outline.writeEnabled = false;</script>


<dd>Catmull-rom interpolation function
<br><br>
<b>Params:</b><br>
<table><tr>
<td nowrap valign="top" style="padding-right: 8px">float <span class="funcparam">t</span></td>

               
<td>= time, <span class="funcparam">a</span> float from [0, 1]</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">a</span></td>

               
<td>= first value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">b</span></td>

               
<td>= second value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">c</span></td>

               
<td>= third value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">d</span></td>

               
<td>= fourth value</td></tr>
<tr>
<td nowrap valign="top" style="padding-right: 8px">T <span class="funcparam">res</span></td>

               
<td>= <span class="funcparam">a</span> place to put the result in</td></tr>
</table><br>

</dd>
</dl>
<script>explorer.outline.decSymbolLevel();</script>


</dd>
</dl>
<script>explorer.outline.decSymbolLevel();</script>


</td></tr>
		<tr><td id="docfooter">
			Page was generated with
			<img src="candydoc/img/candydoc.gif" style="vertical-align:middle; position:relative; top:-1px">
			on Wed Mar 21 02:44:07 2007

		</td></tr>
	</table>
</div>
<script>
   explorer.packageExplorer.addModule("necrophilia.Exception");
   explorer.packageExplorer.addModule("necrophilia.Time");
   explorer.packageExplorer.addModule("necrophilia.helpers.Callback");
   explorer.packageExplorer.addModule("necrophilia.helpers.Interpolation");
   explorer.packageExplorer.addModule("necrophilia.helpers.ListArray");
   explorer.packageExplorer.addModule("necrophilia.animation.Base");
   explorer.packageExplorer.addModule("necrophilia.animation.DataNodes");
   explorer.packageExplorer.addModule("necrophilia.animation.Instance");
   explorer.packageExplorer.addModule("necrophilia.animation.Inteligent");
   explorer.packageExplorer.addModule("necrophilia.skeleton.DataNodes");
   explorer.packageExplorer.addModule("necrophilia.skeleton.Bone");
   explorer.packageExplorer.addModule("necrophilia.skeleton.Skeleton");</script>
</body></html>


